<template>
<div class="means-box">
    <el-row class="means-row">
      <el-col :span="6" style="float:left; margin-left: 45vw;width: 270px; height: 40px;">
        <el-input
          type="text"
          prefix-icon="el-icon-search"
          v-model="kb_content"
          placeholder="请输入"
          style="width: 270px; cursor: pointer"
          @keyup.enter.native="getAllKb"
        >
        </el-input>
      </el-col>
    </el-row>
    <el-collapse v-model="activeName" accordion class="means-collapse">
        <el-collapse-item title="药材外观特点" name="1">
            <div class="content">XXX药材外呈现……状</div>
            <div class="content">经过饮片化处理后，可形态发生改变，此时成……</div>
        </el-collapse-item>
        <el-collapse-item title="药材主要作用" name="2">
            <div class="content">当XXX药材处于&状态时，可以采用外敷/内服方式……</div>
            <div class="content">经过处理后，可以做……用途</div>
        </el-collapse-item>
        <el-collapse-item title="药材市场价格" name="3">
            <div class="content">XXX药材在20XX年-20XX年间的市场交易价格为：…………</div>
            <div class="content">产生如此变化的原因是……</div>
        </el-collapse-item>
        <el-collapse-item title="药材注意事项" name="4">
            <div class="content">XXX药材在使用时应当……</div>
            <div class="content">过程中若出现……的情况时，应当……</div>
        </el-collapse-item>
    </el-collapse>
</div>
</template>

<script>
  export default {
    data() {
      return {
        kb_content: '', // 确保这里初始化为空字符串或其他默认值
        activeName: '1', // 如果这是<el-collapse>的v-model绑定的属性，确保它被定义
        fileList: []
      };
    },
    methods: {
      getAllKb() {
        // 你的逻辑代码
      }
    },
  }
</script>

<style scoped>
.means-box {
  margin-top: 20px;
  padding: 20px;
}

.means-collapse {
  padding: 5px;
  background-color: #5ba58a8b;
}


::v-deep .el-collapse-item__header {
  padding: 5px;
  background-color: #5ba58a8b;
  font-family: SimSun;
  font-size: 20px;
}

::v-deep .el-collapse-item__content {
  background-color: #5ba58ad8;
  padding: 5px;
}

.means-collapse .content {
  font-family: SimSun;
  font-size: 16px;
  padding: 5px;
  background-color: #5ba58ad8;
}
</style>
